package com.itheima.stock.controller;

import com.itheima.stock.api.StockControllerAPI;
import com.itheima.stock.entity.StockBusiness;
import com.itheima.stock.response.ResponseResult;
import com.itheima.stock.service.StockBusinessService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 *
 *
 * @author blusr
 * @version 1.0
 * @date 2025/10/21 14:23
 */
@RestController
public class StockController implements StockControllerAPI {
    @Autowired
    private StockBusinessService stockBusinessService;

    @Override
    public ResponseResult<List<StockBusiness>> getAll() {
        return ResponseResult.ok(stockBusinessService.getAll());
    }
}
